package com.example.gclove.service.impl;

import com.example.gclove.mapper.UserMapper;
import com.example.gclove.pojo.User;
import com.example.gclove.service.UserService;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserServiceImpl implements UserService {

    @Autowired
    private UserMapper userMapper;
    @Override
    public List<User> findAllUser() {
        return userMapper.findAllUser();
    }

    public void addUser(@Param("username") int username, @Param("password") String password, @Param("code") int code){
        userMapper.addUser(username,password,code);
    }




}
